function [x_Jh_nsfoot_mat] = Jh_nsfoot_mat(x)
x_Jh_nsfoot_mat=[1.,0.,(-0.0508).*(cos(x(3)) + 8..*(cos(x(3) + x(4)) + cos(x(3) +  ...
  x(4) + x(5)) + (-2.).*cos(x(3) + x(4) + x(5) + x(6) + (-1.).*x(7)  ...
  + (-0.5).*x(8)).*cos(0.5.*x(8))) + (-3.).*sin(x(3))),(-0.4064).*( ...
  cos(x(3) + x(4)) + cos(x(3) + x(4) + x(5)) + (-2.).*cos(x(3) + x( ...
  4) + x(5) + x(6) + (-1.).*x(7) + (-0.5).*x(8)).*cos(0.5.*x(8))),( ...
  -0.4064).*(cos(x(3) + x(4) + x(5)) + (-2.).*cos(x(3) + x(4) + x(5) ...
   + x(6) + (-1.).*x(7) + (-0.5).*x(8)).*cos(0.5.*x(8))),0.8128.* ...
  cos(x(3) + x(4) + x(5) + x(6) + (-1.).*x(7) + (-0.5).*x(8)).*cos( ...
  0.5.*x(8)),(-0.8128).*cos(x(3) + x(4) + x(5) + x(6) + (-1.).*x(7)  ...
  + (-0.5).*x(8)).*cos(0.5.*x(8)),(-0.4064).*cos(x(3) + x(4) + x(5)  ...
  + x(6) + (-1.).*x(7) + (-1.).*x(8)),0.;0.,1.,(-0.0508).*(3..*cos( ...
  x(3)) + sin(x(3)) + 8..*(sin(x(3) + x(4)) + sin(x(3) + x(4) + x(5) ...
  ) + (-2.).*cos(0.5.*x(8)).*sin(x(3) + x(4) + x(5) + x(6) + (-1.).* ...
  x(7) + (-0.5).*x(8)))),(-0.4064).*(sin(x(3) + x(4)) + sin(x(3) +  ...
  x(4) + x(5)) + (-2.).*cos(0.5.*x(8)).*sin(x(3) + x(4) + x(5) + x( ...
  6) + (-1.).*x(7) + (-0.5).*x(8))),(-0.4064).*(sin(x(3) + x(4) + x( ...
  5)) + (-2.).*cos(0.5.*x(8)).*sin(x(3) + x(4) + x(5) + x(6) + (-1.) ...
  .*x(7) + (-0.5).*x(8))),0.8128.*cos(0.5.*x(8)).*sin(x(3) + x(4) +  ...
  x(5) + x(6) + (-1.).*x(7) + (-0.5).*x(8)),(-0.8128).*cos(0.5.*x(8) ...
  ).*sin(x(3) + x(4) + x(5) + x(6) + (-1.).*x(7) + (-0.5).*x(8)),( ...
  -0.4064).*sin(x(3) + x(4) + x(5) + x(6) + (-1.).*x(7) + (-1.).*x( ...
  8)),0.;0.,0.,(-1.),(-1.),(-1.),(-1.),1.,1.,1.];
